package com.example.demo.SinglePattern;

/**
 * @author gyq
 * @description 单例模式 懒汉模式
 * @datetime 2019/2/23 19:40
 */
public class SingleLazyPattern {
    private static SingleLazyPattern singleHungryPatterns;

    private SingleLazyPattern() {
    }

    public static SingleLazyPattern getInstance() {
        if (null == singleHungryPatterns) {
            singleHungryPatterns = new SingleLazyPattern();
        }
        return singleHungryPatterns;
    }
}
